package com.dhl.service.impl;

import com.dhl.annotation.Autowired;
import com.dhl.annotation.Component;
import com.dhl.annotation.PostConstruct;
import com.dhl.aware.BeanNameAware;
import com.dhl.init.BeanPostProcessor;
import com.dhl.init.InitializingBean;
import com.dhl.mapper.UserMapper;
import com.dhl.service.UserService;

import java.lang.reflect.InvocationHandler;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.lang.reflect.Proxy;

/**
 * @author danghailiang
 * @date 2023年01月16日 10:06
 */
@Component("userService")
public class UserServiceImpl implements UserService , BeanNameAware {


    @Autowired
    private UserMapper userMapper;

    @PostConstruct
    public void test(){
        System.out.println("PostConstruct");
    }

    public void printTest(){
        System.out.println(this);
    }

    public void afterPropertiesSet() {
        System.out.println("afterPropertiesSet");
    }


    public void beanName(String beanName) {
        System.out.println("beanName:::"+beanName);
    }
}
